import { CSSProperties } from 'react';

export interface YuqueEditorProps {
  className?: string;
  style?: CSSProperties;
  defaultValue?: string;
  onChange?: (content: string) => void;
  config?: Record<string, any>;
  onError?: (error: Error) => void;
}

export interface EditorInstance {
  setDocument: (format: string, content: string) => void;
  getDocument: (format: string) => string;
  destroy: () => void;
  on: (event: string, handler: (...args: any[]) => void) => void;
}
